<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="UTF-8" />
        <meta name="robots" content="index, follow, all" />
        <title>Imagine\Gd\Image | Imagine API</title>
                    <link rel="stylesheet" type="text/css" href="../../stylesheet.css">
                            </head>
        <body id="class">
            <div class="header">
        <ul>
            <li><a href="../../classes.html">Classes</a></li>
                            <li><a href="../../namespaces.html">Namespaces</a></li>
                        <li><a href="../../interfaces.html">Interfaces</a></li>
            <li><a href="../../doc-index.html">Index</a></li>
            
        </ul>

        <div id="title">Imagine API</div>

            <div class="type">Class</div>
    <h1><a href="../../Imagine/Gd.html">Imagine\Gd</a>\Image</h1>
    </div>
        <div class="content">
                <p>class    <strong>Image</strong>        implements
        <a href="../../Imagine/Image/ImageInterface.html"><abbr title="Imagine\Image\ImageInterface">ImageInterface</abbr></a></p>

            <div class="description">
            <p>Image implementation using the GD library</p>
            <p>
</p>
        </div>
    
    
    
            <h2>Methods</h2>

            <table>
                    <tr>
                <td class="type">
                    
                </td>
                <td class="last">
                    <a href="#method___construct">__construct</a>(<abbr title="Imagine\Gd\resource">resource</abbr> $resource)
                    <p>Constructs a new Image instance using the result of imagecreatetruecolor()</p>
                </td>
                <td></td>
            </tr>
                    <tr>
                <td class="type">
                    
                </td>
                <td class="last">
                    <a href="#method___destruct">__destruct</a>()
                    <p>Makes sure the current image resource is destroyed</p>
                </td>
                <td></td>
            </tr>
                    <tr>
                <td class="type">
                    <abbr title="Imagine\Gd\resource">resource</abbr>
                </td>
                <td class="last">
                    <a href="#method_getGdResource">getGdResource</a>()
                    <p>Returns Gd resource</p>
                </td>
                <td></td>
            </tr>
                    <tr>
                <td class="type">
                    <a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a>
                </td>
                <td class="last">
                    <a href="#method_copy">copy</a>()
                    <p>Copies current source image into a new ImageInterface instance</p>
                </td>
                <td></td>
            </tr>
                    <tr>
                <td class="type">
                    <a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a>
                </td>
                <td class="last">
                    <a href="#method_crop">crop</a>(<a href="../../Imagine/Image/PointInterface.html"><abbr title="Imagine\Image\PointInterface">PointInterface</abbr></a> $start, <a href="../../Imagine/Image/BoxInterface.html"><abbr title="Imagine\Image\BoxInterface">BoxInterface</abbr></a> $size)
                    <p>Crops a specified box out of the source image (modifies the source image) Returns cropped self</p>
                </td>
                <td></td>
            </tr>
                    <tr>
                <td class="type">
                    <a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a>
                </td>
                <td class="last">
                    <a href="#method_paste">paste</a>(<a href="../../Imagine/Image/ImageInterface.html"><abbr title="Imagine\Image\ImageInterface">ImageInterface</abbr></a> $image, <a href="../../Imagine/Image/PointInterface.html"><abbr title="Imagine\Image\PointInterface">PointInterface</abbr></a> $start)
                    <p>Pastes an image into a parent image Throws exceptions if image exceeds parent image borders or if paste operation fails</p>
                </td>
                <td></td>
            </tr>
                    <tr>
                <td class="type">
                    <a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a>
                </td>
                <td class="last">
                    <a href="#method_resize">resize</a>(<a href="../../Imagine/Image/BoxInterface.html"><abbr title="Imagine\Image\BoxInterface">BoxInterface</abbr></a> $size, string $filter = ImageInterface::FILTER_UNDEFINED)
                    <p>Resizes current image and returns self</p>
                </td>
                <td></td>
            </tr>
                    <tr>
                <td class="type">
                    <a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a>
                </td>
                <td class="last">
                    <a href="#method_rotate">rotate</a>(integer $angle, <a href="../../Imagine/Image/Color.html"><abbr title="Imagine\Image\Color">Color</abbr></a> $background = null)
                    <p>Rotates an image at the given angle.</p>
                </td>
                <td></td>
            </tr>
                    <tr>
                <td class="type">
                    <a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a>
                </td>
                <td class="last">
                    <a href="#method_save">save</a>(string $path, array $options = array())
                    <p>Saves the image at a specified path, the target file extension is used to determine file format, only jpg, jpeg, gif, png, wbmp and xbm are supported</p>
                </td>
                <td></td>
            </tr>
                    <tr>
                <td class="type">
                    <a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a>
                </td>
                <td class="last">
                    <a href="#method_show">show</a>(string $format, array $options = array())
                    <p>Outputs the image content</p>
                </td>
                <td></td>
            </tr>
                    <tr>
                <td class="type">
                    string
                </td>
                <td class="last">
                    <a href="#method_get">get</a>(string $format, array $options = array())
                    <p>Returns the image content as a binary string</p>
                </td>
                <td></td>
            </tr>
                    <tr>
                <td class="type">
                    string
                </td>
                <td class="last">
                    <a href="#method___toString">__toString</a>()
                    <p>Returns the image content as a PNG binary string</p>
                </td>
                <td></td>
            </tr>
                    <tr>
                <td class="type">
                    <a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a>
                </td>
                <td class="last">
                    <a href="#method_flipHorizontally">flipHorizontally</a>()
                    <p>Flips current image using horizontal axis</p>
                </td>
                <td></td>
            </tr>
                    <tr>
                <td class="type">
                    <a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a>
                </td>
                <td class="last">
                    <a href="#method_flipVertically">flipVertically</a>()
                    <p>Flips current image using vertical axis</p>
                </td>
                <td></td>
            </tr>
                    <tr>
                <td class="type">
                    <a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a>
                </td>
                <td class="last">
                    <a href="#method_strip">strip</a>()
                    <p>Remove all profiles and comments</p>
                </td>
                <td></td>
            </tr>
                    <tr>
                <td class="type">
                    <a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a>
                </td>
                <td class="last">
                    <a href="#method_thumbnail">thumbnail</a>(<a href="../../Imagine/Image/BoxInterface.html"><abbr title="Imagine\Image\BoxInterface">BoxInterface</abbr></a> $size, string $mode = ImageInterface::THUMBNAIL_INSET)
                    <p>Generates a thumbnail from a current image Returns it as a new image, doesn't modify the current image</p>
                </td>
                <td></td>
            </tr>
                    <tr>
                <td class="type">
                    <a href="../../Imagine/Draw/DrawerInterface.html"><abbr title="Imagine\Draw\DrawerInterface">DrawerInterface</abbr></a>
                </td>
                <td class="last">
                    <a href="#method_draw">draw</a>()
                    <p>Instantiates and returns a DrawerInterface instance for image drawing</p>
                </td>
                <td></td>
            </tr>
                    <tr>
                <td class="type">
                    <a href="../../Imagine/Effects/EffectsInterface.html"><abbr title="Imagine\Effects\EffectsInterface">EffectsInterface</abbr></a>
                </td>
                <td class="last">
                    <a href="#method_effects">effects</a>()
                    <p>
</p>
                </td>
                <td></td>
            </tr>
                    <tr>
                <td class="type">
                    <a href="../../Imagine/Image/BoxInterface.html"><abbr title="Imagine\Image\BoxInterface">BoxInterface</abbr></a>
                </td>
                <td class="last">
                    <a href="#method_getSize">getSize</a>()
                    <p>Returns current image size</p>
                </td>
                <td></td>
            </tr>
                    <tr>
                <td class="type">
                    <a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a>
                </td>
                <td class="last">
                    <a href="#method_applyMask">applyMask</a>(<a href="../../Imagine/Image/ImageInterface.html"><abbr title="Imagine\Image\ImageInterface">ImageInterface</abbr></a> $mask)
                    <p>Applies a given mask to current image's alpha channel</p>
                </td>
                <td></td>
            </tr>
                    <tr>
                <td class="type">
                    <a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a>
                </td>
                <td class="last">
                    <a href="#method_fill">fill</a>(<a href="../../Imagine/Image/Fill/FillInterface.html"><abbr title="Imagine\Image\Fill\FillInterface">FillInterface</abbr></a> $fill)
                    <p>Fills image with provided filling, by replacing each pixel's color in the current image with corresponding color from FillInterface, and returns modified image</p>
                </td>
                <td></td>
            </tr>
                    <tr>
                <td class="type">
                    <a href="../../Imagine/Image/ImageInterface.html"><abbr title="Imagine\Image\ImageInterface">ImageInterface</abbr></a>
                </td>
                <td class="last">
                    <a href="#method_mask">mask</a>()
                    <p>Transforms creates a grayscale mask from current image, returns a new image, while keeping the existing image unmodified</p>
                </td>
                <td></td>
            </tr>
                    <tr>
                <td class="type">
                    array
                </td>
                <td class="last">
                    <a href="#method_histogram">histogram</a>()
                    <p>Returns array of image colors as Imagine\Image\Color instances</p>
                </td>
                <td></td>
            </tr>
                    <tr>
                <td class="type">
                    <a href="../../Imagine/Image/Color.html"><abbr title="Imagine\Image\Color">Color</abbr></a>
                </td>
                <td class="last">
                    <a href="#method_getColorAt">getColorAt</a>(<a href="../../Imagine/Image/PointInterface.html"><abbr title="Imagine\Image\PointInterface">PointInterface</abbr></a> $point)
                    <p>Returns color at specified positions of current image</p>
                </td>
                <td></td>
            </tr>
                    <tr>
                <td class="type">
                    <a href="../../Imagine/Image/LayersInterface.html"><abbr title="Imagine\Image\LayersInterface">LayersInterface</abbr></a>
                </td>
                <td class="last">
                    <a href="#method_layers">layers</a>()
                    <p>Returns the image layers when applicable.</p>
                </td>
                <td></td>
            </tr>
                    <tr>
                <td class="type">
                    <a href="../../Imagine/Image/ImageInterface.html"><abbr title="Imagine\Image\ImageInterface">ImageInterface</abbr></a>
                </td>
                <td class="last">
                    <a href="#method_interlace">interlace</a>(string $scheme)
                    <p>Enables or disables interlacing</p>
                </td>
                <td></td>
            </tr>
            </table>


        <h2>Details</h2>

                        <h3 id="method___construct">
        <div class="location">at line 42</div>
        <code>            public            
    <strong>__construct</strong>(<abbr title="Imagine\Gd\resource">resource</abbr> $resource)</code>
    </h3>
    <div class="details">
        <p>Constructs a new Image instance using the result of imagecreatetruecolor()</p>
        <p>
</p>
        <div class="tags">
                            <h4>Parameters</h4>

                    <table>
                    <tr>
                <td><abbr title="Imagine\Gd\resource">resource</abbr></td>
                <td>$resource</td>
                <td>
</td>
            </tr>
            </table>

            
            
            
                    </div>
    </div>

                <h3 id="method___destruct">
        <div class="location">at line 50</div>
        <code>            public            
    <strong>__destruct</strong>()</code>
    </h3>
    <div class="details">
        <p>Makes sure the current image resource is destroyed</p>
        <p>
</p>
        <div class="tags">
            
            
            
                    </div>
    </div>

                <h3 id="method_getGdResource">
        <div class="location">at line 62</div>
        <code>            public            <abbr title="Imagine\Gd\resource">resource</abbr>
    <strong>getGdResource</strong>()</code>
    </h3>
    <div class="details">
        <p>Returns Gd resource</p>
        <p>
</p>
        <div class="tags">
            
                            <h4>Return Value</h4>

                    <table>
        <tr>
            <td><abbr title="Imagine\Gd\resource">resource</abbr></td>
            <td>
</td>
        </tr>
    </table>

            
            
                    </div>
    </div>

                <h3 id="method_copy">
        <div class="location">at line 70</div>
        <code>final            public            <a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a>
    <strong>copy</strong>()</code>
    </h3>
    <div class="details">
        <p>Copies current source image into a new ImageInterface instance</p>
        <p>
</p>
        <div class="tags">
            
                            <h4>Return Value</h4>

                    <table>
        <tr>
            <td><a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a></td>
            <td>
</td>
        </tr>
    </table>

            
                            <h4>Exceptions</h4>

                    <table>
                    <tr>
                <td><a href="http://php.net/RuntimeException"><abbr title="RuntimeException">RuntimeException</abbr></a></td>
                <td>
</td>
            </tr>
            </table>

            
                    </div>
    </div>

                <h3 id="method_crop">
        <div class="location">at line 87</div>
        <code>final            public            <a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a>
    <strong>crop</strong>(<a href="../../Imagine/Image/PointInterface.html"><abbr title="Imagine\Image\PointInterface">PointInterface</abbr></a> $start, <a href="../../Imagine/Image/BoxInterface.html"><abbr title="Imagine\Image\BoxInterface">BoxInterface</abbr></a> $size)</code>
    </h3>
    <div class="details">
        <p>Crops a specified box out of the source image (modifies the source image) Returns cropped self</p>
        <p>
</p>
        <div class="tags">
                            <h4>Parameters</h4>

                    <table>
                    <tr>
                <td><a href="../../Imagine/Image/PointInterface.html"><abbr title="Imagine\Image\PointInterface">PointInterface</abbr></a></td>
                <td>$start</td>
                <td>
</td>
            </tr>
                    <tr>
                <td><a href="../../Imagine/Image/BoxInterface.html"><abbr title="Imagine\Image\BoxInterface">BoxInterface</abbr></a></td>
                <td>$size</td>
                <td>
</td>
            </tr>
            </table>

            
                            <h4>Return Value</h4>

                    <table>
        <tr>
            <td><a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a></td>
            <td>
</td>
        </tr>
    </table>

            
                            <h4>Exceptions</h4>

                    <table>
                    <tr>
                <td><a href="http://php.net/OutOfBoundsException"><abbr title="OutOfBoundsException">OutOfBoundsException</abbr></a></td>
                <td>
</td>
            </tr>
                    <tr>
                <td><a href="http://php.net/RuntimeException"><abbr title="RuntimeException">RuntimeException</abbr></a></td>
                <td>
</td>
            </tr>
            </table>

            
                    </div>
    </div>

                <h3 id="method_paste">
        <div class="location">at line 117</div>
        <code>final            public            <a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a>
    <strong>paste</strong>(<a href="../../Imagine/Image/ImageInterface.html"><abbr title="Imagine\Image\ImageInterface">ImageInterface</abbr></a> $image, <a href="../../Imagine/Image/PointInterface.html"><abbr title="Imagine\Image\PointInterface">PointInterface</abbr></a> $start)</code>
    </h3>
    <div class="details">
        <p>Pastes an image into a parent image Throws exceptions if image exceeds parent image borders or if paste operation fails</p>
        <p>Returns source image</p>
        <div class="tags">
                            <h4>Parameters</h4>

                    <table>
                    <tr>
                <td><a href="../../Imagine/Image/ImageInterface.html"><abbr title="Imagine\Image\ImageInterface">ImageInterface</abbr></a></td>
                <td>$image</td>
                <td>
</td>
            </tr>
                    <tr>
                <td><a href="../../Imagine/Image/PointInterface.html"><abbr title="Imagine\Image\PointInterface">PointInterface</abbr></a></td>
                <td>$start</td>
                <td>
</td>
            </tr>
            </table>

            
                            <h4>Return Value</h4>

                    <table>
        <tr>
            <td><a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a></td>
            <td>
</td>
        </tr>
    </table>

            
                            <h4>Exceptions</h4>

                    <table>
                    <tr>
                <td><a href="http://php.net/InvalidArgumentException"><abbr title="InvalidArgumentException">InvalidArgumentException</abbr></a></td>
                <td>
</td>
            </tr>
                    <tr>
                <td><a href="http://php.net/OutOfBoundsException"><abbr title="OutOfBoundsException">OutOfBoundsException</abbr></a></td>
                <td>
</td>
            </tr>
                    <tr>
                <td><a href="http://php.net/RuntimeException"><abbr title="RuntimeException">RuntimeException</abbr></a></td>
                <td>
</td>
            </tr>
            </table>

            
                    </div>
    </div>

                <h3 id="method_resize">
        <div class="location">at line 151</div>
        <code>final            public            <a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a>
    <strong>resize</strong>(<a href="../../Imagine/Image/BoxInterface.html"><abbr title="Imagine\Image\BoxInterface">BoxInterface</abbr></a> $size, string $filter = ImageInterface::FILTER_UNDEFINED)</code>
    </h3>
    <div class="details">
        <p>Resizes current image and returns self</p>
        <p>
</p>
        <div class="tags">
                            <h4>Parameters</h4>

                    <table>
                    <tr>
                <td><a href="../../Imagine/Image/BoxInterface.html"><abbr title="Imagine\Image\BoxInterface">BoxInterface</abbr></a></td>
                <td>$size</td>
                <td>
</td>
            </tr>
                    <tr>
                <td>string</td>
                <td>$filter</td>
                <td>
</td>
            </tr>
            </table>

            
                            <h4>Return Value</h4>

                    <table>
        <tr>
            <td><a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a></td>
            <td>
</td>
        </tr>
    </table>

            
                            <h4>Exceptions</h4>

                    <table>
                    <tr>
                <td><a href="http://php.net/RuntimeException"><abbr title="RuntimeException">RuntimeException</abbr></a></td>
                <td>
</td>
            </tr>
            </table>

            
                    </div>
    </div>

                <h3 id="method_rotate">
        <div class="location">at line 184</div>
        <code>final            public            <a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a>
    <strong>rotate</strong>(integer $angle, <a href="../../Imagine/Image/Color.html"><abbr title="Imagine\Image\Color">Color</abbr></a> $background = null)</code>
    </h3>
    <div class="details">
        <p>Rotates an image at the given angle.</p>
        <p>Optional $background can be used to specify the fill color of the empty
area of rotated image.</p>
        <div class="tags">
                            <h4>Parameters</h4>

                    <table>
                    <tr>
                <td>integer</td>
                <td>$angle</td>
                <td>
</td>
            </tr>
                    <tr>
                <td><a href="../../Imagine/Image/Color.html"><abbr title="Imagine\Image\Color">Color</abbr></a></td>
                <td>$background</td>
                <td>
</td>
            </tr>
            </table>

            
                            <h4>Return Value</h4>

                    <table>
        <tr>
            <td><a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a></td>
            <td>
</td>
        </tr>
    </table>

            
                            <h4>Exceptions</h4>

                    <table>
                    <tr>
                <td><a href="http://php.net/RuntimeException"><abbr title="RuntimeException">RuntimeException</abbr></a></td>
                <td>
</td>
            </tr>
            </table>

            
                    </div>
    </div>

                <h3 id="method_save">
        <div class="location">at line 204</div>
        <code>final            public            <a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a>
    <strong>save</strong>(string $path, array $options = array())</code>
    </h3>
    <div class="details">
        <p>Saves the image at a specified path, the target file extension is used to determine file format, only jpg, jpeg, gif, png, wbmp and xbm are supported</p>
        <p>
</p>
        <div class="tags">
                            <h4>Parameters</h4>

                    <table>
                    <tr>
                <td>string</td>
                <td>$path</td>
                <td>
</td>
            </tr>
                    <tr>
                <td>array</td>
                <td>$options</td>
                <td>
</td>
            </tr>
            </table>

            
                            <h4>Return Value</h4>

                    <table>
        <tr>
            <td><a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a></td>
            <td>
</td>
        </tr>
    </table>

            
                            <h4>Exceptions</h4>

                    <table>
                    <tr>
                <td><a href="http://php.net/RuntimeException"><abbr title="RuntimeException">RuntimeException</abbr></a></td>
                <td>
</td>
            </tr>
            </table>

            
                    </div>
    </div>

                <h3 id="method_show">
        <div class="location">at line 218</div>
        <code>            public            <a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a>
    <strong>show</strong>(string $format, array $options = array())</code>
    </h3>
    <div class="details">
        <p>Outputs the image content</p>
        <p>
</p>
        <div class="tags">
                            <h4>Parameters</h4>

                    <table>
                    <tr>
                <td>string</td>
                <td>$format</td>
                <td>
</td>
            </tr>
                    <tr>
                <td>array</td>
                <td>$options</td>
                <td>
</td>
            </tr>
            </table>

            
                            <h4>Return Value</h4>

                    <table>
        <tr>
            <td><a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a></td>
            <td>
</td>
        </tr>
    </table>

            
                            <h4>Exceptions</h4>

                    <table>
                    <tr>
                <td><a href="http://php.net/RuntimeException"><abbr title="RuntimeException">RuntimeException</abbr></a></td>
                <td>
</td>
            </tr>
            </table>

            
                    </div>
    </div>

                <h3 id="method_get">
        <div class="location">at line 230</div>
        <code>            public            string
    <strong>get</strong>(string $format, array $options = array())</code>
    </h3>
    <div class="details">
        <p>Returns the image content as a binary string</p>
        <p>
</p>
        <div class="tags">
                            <h4>Parameters</h4>

                    <table>
                    <tr>
                <td>string</td>
                <td>$format</td>
                <td>
</td>
            </tr>
                    <tr>
                <td>array</td>
                <td>$options</td>
                <td>
</td>
            </tr>
            </table>

            
                            <h4>Return Value</h4>

                    <table>
        <tr>
            <td>string</td>
            <td>binary</td>
        </tr>
    </table>

            
                            <h4>Exceptions</h4>

                    <table>
                    <tr>
                <td><a href="http://php.net/RuntimeException"><abbr title="RuntimeException">RuntimeException</abbr></a></td>
                <td>
</td>
            </tr>
            </table>

            
                    </div>
    </div>

                <h3 id="method___toString">
        <div class="location">at line 241</div>
        <code>            public            string
    <strong>__toString</strong>()</code>
    </h3>
    <div class="details">
        <p>Returns the image content as a PNG binary string</p>
        <p>
</p>
        <div class="tags">
            
                            <h4>Return Value</h4>

                    <table>
        <tr>
            <td>string</td>
            <td>binary</td>
        </tr>
    </table>

            
                            <h4>Exceptions</h4>

                    <table>
                    <tr>
                <td><a href="http://php.net/RuntimeException"><abbr title="RuntimeException">RuntimeException</abbr></a></td>
                <td>
</td>
            </tr>
            </table>

            
                    </div>
    </div>

                <h3 id="method_flipHorizontally">
        <div class="location">at line 249</div>
        <code>final            public            <a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a>
    <strong>flipHorizontally</strong>()</code>
    </h3>
    <div class="details">
        <p>Flips current image using horizontal axis</p>
        <p>
</p>
        <div class="tags">
            
                            <h4>Return Value</h4>

                    <table>
        <tr>
            <td><a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a></td>
            <td>
</td>
        </tr>
    </table>

            
                            <h4>Exceptions</h4>

                    <table>
                    <tr>
                <td><a href="http://php.net/RuntimeException"><abbr title="RuntimeException">RuntimeException</abbr></a></td>
                <td>
</td>
            </tr>
            </table>

            
                    </div>
    </div>

                <h3 id="method_flipVertically">
        <div class="location">at line 273</div>
        <code>final            public            <a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a>
    <strong>flipVertically</strong>()</code>
    </h3>
    <div class="details">
        <p>Flips current image using vertical axis</p>
        <p>
</p>
        <div class="tags">
            
                            <h4>Return Value</h4>

                    <table>
        <tr>
            <td><a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a></td>
            <td>
</td>
        </tr>
    </table>

            
                            <h4>Exceptions</h4>

                    <table>
                    <tr>
                <td><a href="http://php.net/RuntimeException"><abbr title="RuntimeException">RuntimeException</abbr></a></td>
                <td>
</td>
            </tr>
            </table>

            
                    </div>
    </div>

                <h3 id="method_strip">
        <div class="location">at line 297</div>
        <code>final            public            <a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a>
    <strong>strip</strong>()</code>
    </h3>
    <div class="details">
        <p>Remove all profiles and comments</p>
        <p>
</p>
        <div class="tags">
            
                            <h4>Return Value</h4>

                    <table>
        <tr>
            <td><a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a></td>
            <td>
</td>
        </tr>
    </table>

            
                            <h4>Exceptions</h4>

                    <table>
                    <tr>
                <td><a href="http://php.net/RuntimeException"><abbr title="RuntimeException">RuntimeException</abbr></a></td>
                <td>
</td>
            </tr>
            </table>

            
                    </div>
    </div>

                <h3 id="method_thumbnail">
        <div class="location">at line 309</div>
        <code>            public            <a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a>
    <strong>thumbnail</strong>(<a href="../../Imagine/Image/BoxInterface.html"><abbr title="Imagine\Image\BoxInterface">BoxInterface</abbr></a> $size, string $mode = ImageInterface::THUMBNAIL_INSET)</code>
    </h3>
    <div class="details">
        <p>Generates a thumbnail from a current image Returns it as a new image, doesn't modify the current image</p>
        <p>
</p>
        <div class="tags">
                            <h4>Parameters</h4>

                    <table>
                    <tr>
                <td><a href="../../Imagine/Image/BoxInterface.html"><abbr title="Imagine\Image\BoxInterface">BoxInterface</abbr></a></td>
                <td>$size</td>
                <td>
</td>
            </tr>
                    <tr>
                <td>string</td>
                <td>$mode</td>
                <td>
</td>
            </tr>
            </table>

            
                            <h4>Return Value</h4>

                    <table>
        <tr>
            <td><a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a></td>
            <td>
</td>
        </tr>
    </table>

            
                            <h4>Exceptions</h4>

                    <table>
                    <tr>
                <td><a href="http://php.net/RuntimeException"><abbr title="RuntimeException">RuntimeException</abbr></a></td>
                <td>
</td>
            </tr>
            </table>

            
                    </div>
    </div>

                <h3 id="method_draw">
        <div class="location">at line 366</div>
        <code>            public            <a href="../../Imagine/Draw/DrawerInterface.html"><abbr title="Imagine\Draw\DrawerInterface">DrawerInterface</abbr></a>
    <strong>draw</strong>()</code>
    </h3>
    <div class="details">
        <p>Instantiates and returns a DrawerInterface instance for image drawing</p>
        <p>
</p>
        <div class="tags">
            
                            <h4>Return Value</h4>

                    <table>
        <tr>
            <td><a href="../../Imagine/Draw/DrawerInterface.html"><abbr title="Imagine\Draw\DrawerInterface">DrawerInterface</abbr></a></td>
            <td>
</td>
        </tr>
    </table>

            
            
                    </div>
    </div>

                <h3 id="method_effects">
        <div class="location">at line 374</div>
        <code>            public            <a href="../../Imagine/Effects/EffectsInterface.html"><abbr title="Imagine\Effects\EffectsInterface">EffectsInterface</abbr></a>
    <strong>effects</strong>()</code>
    </h3>
    <div class="details">
        <p>
</p>
        <p>
</p>
        <div class="tags">
            
                            <h4>Return Value</h4>

                    <table>
        <tr>
            <td><a href="../../Imagine/Effects/EffectsInterface.html"><abbr title="Imagine\Effects\EffectsInterface">EffectsInterface</abbr></a></td>
            <td>
</td>
        </tr>
    </table>

            
            
                    </div>
    </div>

                <h3 id="method_getSize">
        <div class="location">at line 382</div>
        <code>            public            <a href="../../Imagine/Image/BoxInterface.html"><abbr title="Imagine\Image\BoxInterface">BoxInterface</abbr></a>
    <strong>getSize</strong>()</code>
    </h3>
    <div class="details">
        <p>Returns current image size</p>
        <p>
</p>
        <div class="tags">
            
                            <h4>Return Value</h4>

                    <table>
        <tr>
            <td><a href="../../Imagine/Image/BoxInterface.html"><abbr title="Imagine\Image\BoxInterface">BoxInterface</abbr></a></td>
            <td>
</td>
        </tr>
    </table>

            
            
                    </div>
    </div>

                <h3 id="method_applyMask">
        <div class="location">at line 390</div>
        <code>            public            <a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a>
    <strong>applyMask</strong>(<a href="../../Imagine/Image/ImageInterface.html"><abbr title="Imagine\Image\ImageInterface">ImageInterface</abbr></a> $mask)</code>
    </h3>
    <div class="details">
        <p>Applies a given mask to current image's alpha channel</p>
        <p>
</p>
        <div class="tags">
                            <h4>Parameters</h4>

                    <table>
                    <tr>
                <td><a href="../../Imagine/Image/ImageInterface.html"><abbr title="Imagine\Image\ImageInterface">ImageInterface</abbr></a></td>
                <td>$mask</td>
                <td>
</td>
            </tr>
            </table>

            
                            <h4>Return Value</h4>

                    <table>
        <tr>
            <td><a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a></td>
            <td>
</td>
        </tr>
    </table>

            
            
                    </div>
    </div>

                <h3 id="method_fill">
        <div class="location">at line 430</div>
        <code>            public            <a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a>
    <strong>fill</strong>(<a href="../../Imagine/Image/Fill/FillInterface.html"><abbr title="Imagine\Image\Fill\FillInterface">FillInterface</abbr></a> $fill)</code>
    </h3>
    <div class="details">
        <p>Fills image with provided filling, by replacing each pixel's color in the current image with corresponding color from FillInterface, and returns modified image</p>
        <p>
</p>
        <div class="tags">
                            <h4>Parameters</h4>

                    <table>
                    <tr>
                <td><a href="../../Imagine/Image/Fill/FillInterface.html"><abbr title="Imagine\Image\Fill\FillInterface">FillInterface</abbr></a></td>
                <td>$fill</td>
                <td>
</td>
            </tr>
            </table>

            
                            <h4>Return Value</h4>

                    <table>
        <tr>
            <td><a href="../../Imagine/Image/ManipulatorInterface.html"><abbr title="Imagine\Image\ManipulatorInterface">ManipulatorInterface</abbr></a></td>
            <td>
</td>
        </tr>
    </table>

            
            
                    </div>
    </div>

                <h3 id="method_mask">
        <div class="location">at line 452</div>
        <code>            public            <a href="../../Imagine/Image/ImageInterface.html"><abbr title="Imagine\Image\ImageInterface">ImageInterface</abbr></a>
    <strong>mask</strong>()</code>
    </h3>
    <div class="details">
        <p>Transforms creates a grayscale mask from current image, returns a new image, while keeping the existing image unmodified</p>
        <p>
</p>
        <div class="tags">
            
                            <h4>Return Value</h4>

                    <table>
        <tr>
            <td><a href="../../Imagine/Image/ImageInterface.html"><abbr title="Imagine\Image\ImageInterface">ImageInterface</abbr></a></td>
            <td>
</td>
        </tr>
    </table>

            
            
                    </div>
    </div>

                <h3 id="method_histogram">
        <div class="location">at line 466</div>
        <code>            public            array
    <strong>histogram</strong>()</code>
    </h3>
    <div class="details">
        <p>Returns array of image colors as Imagine\Image\Color instances</p>
        <p>
</p>
        <div class="tags">
            
                            <h4>Return Value</h4>

                    <table>
        <tr>
            <td>array</td>
            <td>
</td>
        </tr>
    </table>

            
            
                    </div>
    </div>

                <h3 id="method_getColorAt">
        <div class="location">at line 483</div>
        <code>            public            <a href="../../Imagine/Image/Color.html"><abbr title="Imagine\Image\Color">Color</abbr></a>
    <strong>getColorAt</strong>(<a href="../../Imagine/Image/PointInterface.html"><abbr title="Imagine\Image\PointInterface">PointInterface</abbr></a> $point)</code>
    </h3>
    <div class="details">
        <p>Returns color at specified positions of current image</p>
        <p>
</p>
        <div class="tags">
                            <h4>Parameters</h4>

                    <table>
                    <tr>
                <td><a href="../../Imagine/Image/PointInterface.html"><abbr title="Imagine\Image\PointInterface">PointInterface</abbr></a></td>
                <td>$point</td>
                <td>
</td>
            </tr>
            </table>

            
                            <h4>Return Value</h4>

                    <table>
        <tr>
            <td><a href="../../Imagine/Image/Color.html"><abbr title="Imagine\Image\Color">Color</abbr></a></td>
            <td>
</td>
        </tr>
    </table>

            
                            <h4>Exceptions</h4>

                    <table>
                    <tr>
                <td><a href="http://php.net/RuntimeException"><abbr title="RuntimeException">RuntimeException</abbr></a></td>
                <td>
</td>
            </tr>
            </table>

            
                    </div>
    </div>

                <h3 id="method_layers">
        <div class="location">at line 506</div>
        <code>            public            <a href="../../Imagine/Image/LayersInterface.html"><abbr title="Imagine\Image\LayersInterface">LayersInterface</abbr></a>
    <strong>layers</strong>()</code>
    </h3>
    <div class="details">
        <p>Returns the image layers when applicable.</p>
        <p>
</p>
        <div class="tags">
            
                            <h4>Return Value</h4>

                    <table>
        <tr>
            <td><a href="../../Imagine/Image/LayersInterface.html"><abbr title="Imagine\Image\LayersInterface">LayersInterface</abbr></a></td>
            <td>
</td>
        </tr>
    </table>

            
                            <h4>Exceptions</h4>

                    <table>
                    <tr>
                <td><a href="http://php.net/RuntimeException"><abbr title="RuntimeException">RuntimeException</abbr></a></td>
                <td>In case the layer can not be returned</td>
            </tr>
                    <tr>
                <td><a href="http://php.net/OutOfBoundsException"><abbr title="OutOfBoundsException">OutOfBoundsException</abbr></a></td>
                <td>In case the index is not a valid value</td>
            </tr>
            </table>

            
                    </div>
    </div>

                <h3 id="method_interlace">
        <div class="location">at line 518</div>
        <code>            public            <a href="../../Imagine/Image/ImageInterface.html"><abbr title="Imagine\Image\ImageInterface">ImageInterface</abbr></a>
    <strong>interlace</strong>(string $scheme)</code>
    </h3>
    <div class="details">
        <p>Enables or disables interlacing</p>
        <p>
</p>
        <div class="tags">
                            <h4>Parameters</h4>

                    <table>
                    <tr>
                <td>string</td>
                <td>$scheme</td>
                <td>
</td>
            </tr>
            </table>

            
                            <h4>Return Value</h4>

                    <table>
        <tr>
            <td><a href="../../Imagine/Image/ImageInterface.html"><abbr title="Imagine\Image\ImageInterface">ImageInterface</abbr></a></td>
            <td>
</td>
        </tr>
    </table>

            
                            <h4>Exceptions</h4>

                    <table>
                    <tr>
                <td><a href="http://php.net/InvalidArgumentException"><abbr title="InvalidArgumentException">InvalidArgumentException</abbr></a></td>
                <td>When an unsupported Interface type is supplied</td>
            </tr>
            </table>

            
                    </div>
    </div>

    
            </div>
            <div id="footer">
        Generated by <a href="http://sami.sensiolabs.org/" target="_top">Sami, the API Documentation Generator</a>.
    </div>
    </body>
</html>
